<?php  if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class ci_session_model extends CI_Model{

	function __construct()
    {
        // Call the Model constructor
        parent::__construct();
    }
	function check_session_by_id($id)
	{
		// return $this->db->where('session_id', $id)->count_all_results($this->tables['ci_sessions']) > 0;
		$query = $this->db->get_where('ci_sessions', array('session_id' => $id), 1);
		return $query->row();
	} 
	function get_all_session()
	{
		// return $this->db->where('session_id', $id)->count_all_results($this->tables['ci_sessions']) > 0;
		$query = $this->db->get('ci_sessions');
		return $query->result();
	} 
	
	
}

?>